package com.sneaker.shower.socket.feature;


import com.sneaker.shower.socket.Channel;
import com.sneaker.shower.socket.Group;
import com.sneaker.shower.socket.common.PSWsRequest;
import com.sneaker.shower.socket.common.PSWsResponse;

import java.io.Serializable;
import java.util.Collection;

/**
 * <h1>SignProxyChannel</h1>
 * <pre>
 * @Description
 * </pre>
 *
 * @Author lopo
 * @Date 2018/10/19
 */
public class SignProxyChannel implements Channel {

    private Channel channel;

    public SignProxyChannel(Channel channel) {
        this.channel = channel;
    }

    @Override
    public void send(Serializable s) {
        channel.send(s);
    }

    @Override
    public Serializable getId() {
        return channel.getId();
    }

    @Override
    public void doAuth(PSWsRequest request, PSWsResponse response) {
        channel.doAuth(request, response);
    }

    @Override
    public void start() {
        channel.start();
    }

    @Override
    public void valid() {
        channel.valid();
    }

    @Override
    public void invalid() {
        channel.invalid();
    }

    @Override
    public void broken() {
        channel.broken();
    }

    @Override
    public Serializable sign() {
        return channel.sign();
    }

    @Override
    public Collection<Group<Channel>> groups() {
        return channel.groups();
    }
}
